Optimal. Leaf size=118 \[ \frac {x \left (c-\frac {a \left (a^2 f-a b e+b^2 d\right )}{b^3}\right )}{2 a \left (a+b x^2\right )}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (5 a^3 f-3 a^2 b e+a b^2 d+b^3 c\right )}{2 a^{3/2} b^{7/2}}+\frac {x (b e-2 a f)}{b^3}+\frac {f x^3}{3 b^2} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.12, antiderivative size = 118, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.111, Rules used = {1814, 1153, 205} \[ \frac {x \left (c-\frac {a \left (a^2 f-a b e+b^2 d\right )}{b^3}\right )}{2 a \left (a+b x^2\right )}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (-3 a^2 b e+5 a^3 f+a b^2 d+b^3 c\right )}{2 a^{3/2} b^{7/2}}+\frac {x (b e-2 a f)}{b^3}+\frac {f x^3}{3 b^2} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 205
Rule 1153
Rule 1814
Rubi steps
\begin {align*} \int \frac {c+d x^2+e x^4+f x^6}{\left (a+b x^2\right )^2} \, dx &=\frac {\left (c-\frac {a \left (b^2 d-a b e+a^2 f\right )}{b^3}\right ) x}{2 a \left (a+b x^2\right )}-\frac {\int \frac {-\frac {b^3 c+a b^2 d-a^2 b e+a^3 f}{b^3}-\frac {2 a (b e-a f) x^2}{b^2}-\frac {2 a f x^4}{b}}{a+b x^2} \, dx}{2 a}\\ &=\frac {\left (c-\frac {a \left (b^2 d-a b e+a^2 f\right )}{b^3}\right ) x}{2 a \left (a+b x^2\right )}-\frac {\int \left (-\frac {2 a (b e-2 a f)}{b^3}-\frac {2 a f x^2}{b^2}+\frac {-b^3 c-a b^2 d+3 a^2 b e-5 a^3 f}{b^3 \left (a+b x^2\right )}\right ) \, dx}{2 a}\\ &=\frac {(b e-2 a f) x}{b^3}+\frac {f x^3}{3 b^2}+\frac {\left (c-\frac {a \left (b^2 d-a b e+a^2 f\right )}{b^3}\right ) x}{2 a \left (a+b x^2\right )}+\frac {\left (b^3 c+a b^2 d-3 a^2 b e+5 a^3 f\right ) \int \frac {1}{a+b x^2} \, dx}{2 a b^3}\\ &=\frac {(b e-2 a f) x}{b^3}+\frac {f x^3}{3 b^2}+\frac {\left (c-\frac {a \left (b^2 d-a b e+a^2 f\right )}{b^3}\right ) x}{2 a \left (a+b x^2\right )}+\frac {\left (b^3 c+a b^2 d-3 a^2 b e+5 a^3 f\right ) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{2 a^{3/2} b^{7/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.10, size = 122, normalized size = 1.03 \[ -\frac {x \left (a^3 f-a^2 b e+a b^2 d-b^3 c\right )}{2 a b^3 \left (a+b x^2\right )}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (5 a^3 f-3 a^2 b e+a b^2 d+b^3 c\right )}{2 a^{3/2} b^{7/2}}+\frac {x (b e-2 a f)}{b^3}+\frac {f x^3}{3 b^2} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.65, size = 364, normalized size = 3.08 \[ \left [\frac {4 \, a^{2} b^{3} f x^{5} + 4 \, {\left (3 \, a^{2} b^{3} e - 5 \, a^{3} b^{2} f\right )} x^{3} - 3 \, {\left (a b^{3} c + a^{2} b^{2} d - 3 \, a^{3} b e + 5 \, a^{4} f + {\left (b^{4} c + a b^{3} d - 3 \, a^{2} b^{2} e + 5 \, a^{3} b f\right )} x^{2}\right )} \sqrt {-a b} \log \left (\frac {b x^{2} - 2 \, \sqrt {-a b} x - a}{b x^{2} + a}\right ) + 6 \, {\left (a b^{4} c - a^{2} b^{3} d + 3 \, a^{3} b^{2} e - 5 \, a^{4} b f\right )} x}{12 \, {\left (a^{2} b^{5} x^{2} + a^{3} b^{4}\right )}}, \frac {2 \, a^{2} b^{3} f x^{5} + 2 \, {\left (3 \, a^{2} b^{3} e - 5 \, a^{3} b^{2} f\right )} x^{3} + 3 \, {\left (a b^{3} c + a^{2} b^{2} d - 3 \, a^{3} b e + 5 \, a^{4} f + {\left (b^{4} c + a b^{3} d - 3 \, a^{2} b^{2} e + 5 \, a^{3} b f\right )} x^{2}\right )} \sqrt {a b} \arctan \left (\frac {\sqrt {a b} x}{a}\right ) + 3 \, {\left (a b^{4} c - a^{2} b^{3} d + 3 \, a^{3} b^{2} e - 5 \, a^{4} b f\right )} x}{6 \, {\left (a^{2} b^{5} x^{2} + a^{3} b^{4}\right )}}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.40, size = 126, normalized size = 1.07 \[ \frac {{\left (b^{3} c + a b^{2} d + 5 \, a^{3} f - 3 \, a^{2} b e\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \, \sqrt {a b} a b^{3}} + \frac {b^{3} c x - a b^{2} d x - a^{3} f x + a^{2} b x e}{2 \, {\left (b x^{2} + a\right )} a b^{3}} + \frac {b^{4} f x^{3} - 6 \, a b^{3} f x + 3 \, b^{4} x e}{3 \, b^{6}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.01, size = 177, normalized size = 1.50 \[ \frac {f \,x^{3}}{3 b^{2}}-\frac {a^{2} f x}{2 \left (b \,x^{2}+a \right ) b^{3}}+\frac {5 a^{2} f \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, b^{3}}+\frac {a e x}{2 \left (b \,x^{2}+a \right ) b^{2}}-\frac {3 a e \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, b^{2}}+\frac {c x}{2 \left (b \,x^{2}+a \right ) a}+\frac {c \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, a}-\frac {d x}{2 \left (b \,x^{2}+a \right ) b}+\frac {d \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, b}-\frac {2 a f x}{b^{3}}+\frac {e x}{b^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 2.97, size = 117, normalized size = 0.99 \[ \frac {{\left (b^{3} c - a b^{2} d + a^{2} b e - a^{3} f\right )} x}{2 \, {\left (a b^{4} x^{2} + a^{2} b^{3}\right )}} + \frac {b f x^{3} + 3 \, {\left (b e - 2 \, a f\right )} x}{3 \, b^{3}} + \frac {{\left (b^{3} c + a b^{2} d - 3 \, a^{2} b e + 5 \, a^{3} f\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \, \sqrt {a b} a b^{3}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.10, size = 113, normalized size = 0.96 \[ x\,\left (\frac {e}{b^2}-\frac {2\,a\,f}{b^3}\right )+\frac {f\,x^3}{3\,b^2}+\frac {x\,\left (-f\,a^3+e\,a^2\,b-d\,a\,b^2+c\,b^3\right )}{2\,a\,\left (b^4\,x^2+a\,b^3\right )}+\frac {\mathrm {atan}\left (\frac {\sqrt {b}\,x}{\sqrt {a}}\right )\,\left (5\,f\,a^3-3\,e\,a^2\,b+d\,a\,b^2+c\,b^3\right )}{2\,a^{3/2}\,b^{7/2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 2.88, size = 201, normalized size = 1.70 \[ x \left (- \frac {2 a f}{b^{3}} + \frac {e}{b^{2}}\right ) + \frac {x \left (- a^{3} f + a^{2} b e - a b^{2} d + b^{3} c\right )}{2 a^{2} b^{3} + 2 a b^{4} x^{2}} - \frac {\sqrt {- \frac {1}{a^{3} b^{7}}} \left (5 a^{3} f - 3 a^{2} b e + a b^{2} d + b^{3} c\right ) \log {\left (- a^{2} b^{3} \sqrt {- \frac {1}{a^{3} b^{7}}} + x \right )}}{4} + \frac {\sqrt {- \frac {1}{a^{3} b^{7}}} \left (5 a^{3} f - 3 a^{2} b e + a b^{2} d + b^{3} c\right ) \log {\left (a^{2} b^{3} \sqrt {- \frac {1}{a^{3} b^{7}}} + x \right )}}{4} + \frac {f x^{3}}{3 b^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________